package com.base.cn.platform.os.dao.book;

import com.base.cn.platform.os.common.mybatis.BaseDao;
import com.base.cn.platform.os.entity.book.Book;
import com.base.cn.platform.os.entity.book.count.BookSumCount;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 图书Dao
 *
 * @author s.li
 * @create 2018-05-08-14:13
 */
@Mapper
public interface BookDao extends BaseDao<Book> {

    /**
     * 查询图书总数量数据
     * @param clazz
     * @return
     */
    BookSumCount queryBookSumCount(@Param("clazz") Class<Book> clazz);

    /**
     * 修改图书库存
     * @param data
     */
    void updateStockNum(@Param("data") List<Map<String,Object>> data);
}
